import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'
import EditView from '../views/EditView.vue'

const routes = [
  {
    path: '/',
    name: 'home',
    component: HomeView
  },
  {
    path: '/edit/:id',
    name: 'edit',
    component: EditView,
    props: true
  },
  {
    path: '/edit/new',
    name: 'edit',
    component: EditView,
    props: true
  },
  {
    path: '/notebooks/new',
    name: 'new',
    component: EditView,
    props: true
  }
]

export const router = createRouter({
  history: createWebHistory(),
  routes,
})

  